﻿package sedie 
{
	import flash.display.MovieClip;
	import flash.text.TextField;
	import game.exchangeddata.HashTable;
	import sedie.exchangeddata.UserLiveBetPoolInfo;
	/**
	 * ...
	 * @author Doan Nguyen Thuy Nha Truc (Bamboo)	
	 */
	public class UserLiveBetPoolPanel extends MovieClip
	{
		public var txtEvenTf:TextField;
		public var txtCardEvenTotalAmtTf:TextField;
		public var txtOddTf:TextField;
		public var txtCardOddTotalAmtTf:TextField;
		
		public var txtCardFourTotalAmtTf:TextField;
		public var txtCardOneTotalAmtTf:TextField;
		public var txtCardZeroTotalAmtTf:TextField;
		public var txtCardThreeTotalAmtTf:TextField;
			
		public function UserLiveBetPoolPanel() 
		{
			
		}
		
		public function initText(hashTableInfo:HashTable):void {
			this.txtOddTf.text = hashTableInfo.lookupString("odd");
			this.txtEvenTf.text = hashTableInfo.lookupString("even");
		}
		
		public function initLivebetPoolUser():void {
			this.txtCardEvenTotalAmtTf.text = "0";
			this.txtCardOddTotalAmtTf.text = "0";
			this.txtCardFourTotalAmtTf.text = "0";
			this.txtCardOneTotalAmtTf.text = "0";
			this.txtCardZeroTotalAmtTf.text = "0";
			this.txtCardThreeTotalAmtTf.text = "0";
			
		}
		
		public function updateLiveBetPoolUser(liveBetPoolUser:UserLiveBetPoolInfo) {
			//trace("updateLiveBetPoolUser:" + liveBetPoolUser.bigTotalAmt);
			this.txtCardZeroTotalAmtTf.text = liveBetPoolUser.cardZeroTotalAmt + "";
			this.txtCardOneTotalAmtTf.text = liveBetPoolUser.cardOneTotalAmt + "";
			this.txtCardThreeTotalAmtTf.text = liveBetPoolUser.cardThreeTotalAmt + "";
			this.txtCardFourTotalAmtTf.text = liveBetPoolUser.cardFourTotalAmt + "";
			this.txtCardOddTotalAmtTf.text = liveBetPoolUser.cardOddTotalAmt + "";
			this.txtCardEvenTotalAmtTf.text = liveBetPoolUser.cardEvenTotalAmt + "";
		}
		
	}

}